package com.andaily.service;

import com.andaily.domain.dto.user.ForgotPasswordDTO;
import com.andaily.domain.dto.user.RegisterUserDTO;
import com.andaily.domain.dto.user.UserFormDTO;
import com.andaily.domain.user.AccountSetting;
import com.andaily.domain.user.User;
import com.andaily.domain.user.UserSetting;

/**
 * @author Shengzhao Li
 */
public interface UserService {

    void saveRegisterUser(RegisterUserDTO registerUserDTO);

    String loadUserGuidByEmail(String email);

    boolean activeRegisterUser(String code);

    void forgotPassword(ForgotPasswordDTO forgotPasswordDTO);

    User currentUser();

    UserSetting loadUserSettingByUserGuid(String userGuid);

    void updateAccountSettingByUserGuid(AccountSetting accountSetting, String userGuid);

    UserFormDTO loadUserFormDTO();

    boolean updateUserSetting(UserFormDTO userFormDTO);

    /**
     * Check the password is current logged user or not
     *
     * @param password password
     * @return True is right
     */
    boolean checkCurrentUserPassword(String password);

    boolean uniqueCellphone(String cellPhone);
}
